   function ask_exists( root , subdir ); 
%   
%  function ask_exists( root , subdir ); 
% 
%  Check if the subdirectory SUBDIR exists in ROOT 
%  if so, ask whether to continue or not 
% 
%  Related function CR_DIR, CH_EXDIR 
%  Alejandro Justiniano 11/2/2005 
% ==============================================
cucd = cd; 
if isempty( root ) 
    root = cucd; 
end 
cd( root ); 
ch = exist( subdir , 'dir' ); 
if ch ~= 0 
    disp(['In ',root ] ); 
    disp(['Subdirectory ',subdir,' already exists ' ] ); 
    quer('c'); 
end 